package com.skytech.tax.customsdatawarehouse.fta.origincredential.domain.entity;


import com.alibaba.fastjson.JSONObject;
import org.joda.time.DateTime;

public class FtaOriginCredential {

    private String id;                //原产地证书ID
    private String docNo;             //原产地证书编号
    private String data;          //原产地证书数据
    private String socialCreditCode;  //企业社会信用代码
    private String submitTime;        //提交时间
    private String storageTime;       //入库时间

    public FtaOriginCredential() {
    }

    public FtaOriginCredential(String socialCreditCode, JSONObject data) {
        this.id = data.getString("id");
        this.docNo = data.getString("docNo");
        this.submitTime = data.getString("submitTime");
        this.data = data.toJSONString();
        this.socialCreditCode = socialCreditCode;
        this.storageTime = DateTime.now().toString("yyyy-MM-dd HH:mm:ss");
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getDocNo() {
        return docNo;
    }

    public void setDocNo(String docNo) {
        this.docNo = docNo;
    }

    public String getData() {
        return data;
    }

    public void setData(String data) {
        this.data = data;
    }

    public String getSocialCreditCode() {
        return socialCreditCode;
    }

    public void setSocialCreditCode(String socialCreditCode) {
        this.socialCreditCode = socialCreditCode;
    }

    public String getSubmitTime() {
        return submitTime;
    }

    public void setSubmitTime(String submitTime) {
        this.submitTime = submitTime;
    }

    public String getStorageTime() {
        return storageTime;
    }

    public void setStorageTime(String storageTime) {
        this.storageTime = storageTime;
    }
}
